package com.webserve.test;

import javax.activation.MimetypesFileTypeMap;
import java.io.File;

public class ContentTypeDemo {
    public static void main(String[] args) {
        MimetypesFileTypeMap mft = new MimetypesFileTypeMap();
        File file = new File("logo.png");
        String ct = mft.getContentType(file);
        System.out.println(ct);
    }
}
